<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>layui</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="../../lib/layui-v2.6.3/css/layui.css" media="all">
    <link rel="stylesheet" href="../../css/public.css" media="all">
    <style>
        body {
            background-color: #ffffff;
        }
    </style>
</head>
<body>
<div class="layui-form layuimini-form">
    <div class="layui-form-item">
        <label class="layui-form-label required">uid</label>
        <div class="layui-input-block">
            <input type="text" name="staff_uid" lay-verify="required" lay-reqtext="uid不能为空" placeholder="请输入uid" value="" class="layui-input">
            <tip>填写修改的uid。</tip>
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label required">基本工资</label>
        <div class="layui-input-block">
            <input type="text" name="salary_basic" placeholder="输入你的基本工资" lay-reqtext="基本工资不能为空" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label required">工作时长</label>
        <div class="layui-input-block">
            <input type="text" name="salary_work_duration" lay-verify="required" lay-reqtext="工作时长不能为空" placeholder="请输入工作时长" value="" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">水电费</label>
        <div class="layui-input-block">
            <input type="text" name="salary_sundry" placeholder="输入水电费" value="" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">全勤奖</label>
        <div class="layui-input-block">
            <input type="text" name="salary_full_attendance" placeholder="请输入全勤奖" value="" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item layui-form-text">
        <label class="layui-form-label">请假次数</label>
        <div class="layui-input-block">
            <input type="text" name="salary_leave" placeholder="请输入请假次数" class="layui-input">
        </div>
    </div>

    <div class="layui-form-item layui-form-text">
        <label class="layui-form-label">应发工资</label>
        <div class="layui-input-block">
            <input type="text" name="salary_payable" placeholder="请输入应发工资" class="layui-input">
        </div>
    </div>

    <div class="layui-form-item layui-form-text">
        <label class="layui-form-label">实发工资</label>
        <div class="layui-input-block">
            <input type="text" name="salary_number" class="layui-input">
        </div>
    </div>


    <div class="layui-form-item">
        <div class="layui-input-block">
            <button class="layui-btn layui-btn-normal" lay-submit lay-filter="saveBtn">确认保存</button>
        </div>
    </div>
</div>
<script src="../../lib/layui-v2.6.3/layui.js" charset="utf-8"></script>
<script>
    layui.use(['form'], function () {
        var form = layui.form,
            layer = layui.layer,
            $ = layui.$;

        //监听提交
        form.on('submit(saveBtn)', function (data) {
            var index = layer.alert(JSON.stringify(data.field), {
                title: '最终的提交信息'
            }, function () {

                // 关闭弹出层
                layer.close(index);

                var iframeIndex = parent.layer.getFrameIndex(window.name);
                parent.layer.close(iframeIndex);

            });

            return false;
        });

    });
</script>
</body>
</html>